package com.neuedu.grainsapi.controller;

import com.neuedu.grainsapi.pojo.SeedRatio;
import com.neuedu.grainsapi.service.SeedRatioService;
import com.neuedu.grainsapi.util.ResponseResult;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
public class SeedRatioController {
    @Autowired
    private SeedRatioService seedRatioService;
    @GetMapping("/querySeedRatio")
    public ResponseResult<List<SeedRatio>> querySeedRatio(){
        List<SeedRatio> seedRatios = seedRatioService.querySeedRatio();
        return new ResponseResult<>("200","yes",seedRatios);
    }
}
